import os
import sys
sys.path.append("..")
from utils import DbPoolUtil
from utils import Properties
from utils import LoggerUtil

config_path = '/opt/config/application.properties' # docker配置文件
if not os.path.exists(config_path):
    config_path = "./config/application.properties" # 本地项目配置文件

dictProperties = Properties.Properties(config_path).getProperties()

dbpool_util = DbPoolUtil.DbPoolUtil(dictProperties)

log_path = '/opt/log'
if not os.path.exists(log_path):
    log_path = './log'
    if not os.path.exists(log_path):
        os.makedirs(log_path)
log_util = LoggerUtil.LoggerUtil(log_path + '/api.log', level='debug')
